package practice;

public class _1到n的和_ {
    public static void main(String[] args) {
        int n = 3;
        System.out.println(Sum_Solution(n));
    }

    public static int Sum_Solution(int n) {
        int res = n;
        boolean flag = (res > 0) && ((res += Sum_Solution(--res)) != 0);
        return res;
    }
}
